import request from '@/utils/request'

// 查询crm系统的树目录列表
export function listCrmtree(query) {
  return request({
    url: '/system/crmtree/list',
    method: 'get',
    params: query
  })
}

// 查询crm系统的树目录详细
export function getCrmtree(treeId) {
  return request({
    url: '/system/crmtree/' + treeId,
    method: 'get'
  })
}

// 新增crm系统的树目录
export function addCrmtree(data) {
  return request({
    url: '/system/crmtree',
    method: 'post',
    data: data
  })
}

// 修改crm系统的树目录
export function updateCrmtree(data) {
  return request({
    url: '/system/crmtree',
    method: 'put',
    data: data
  })
}

// 删除crm系统的树目录
export function delCrmtree(treeId) {
  return request({
    url: '/system/crmtree/' + treeId,
    method: 'delete'
  })
}
